package com.huanxing.cloud.upms.common.feign;

import com.huanxing.cloud.common.core.constant.SecurityConstants;
import com.huanxing.cloud.common.core.constant.ServiceNameConstants;
import com.huanxing.cloud.common.core.entity.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestHeader;

import java.util.List;

@FeignClient(contextId = "feignSysRoleService", value = ServiceNameConstants.UMPS_ADMIN_SERVICE)
public interface FeignSysRoleService {

  @GetMapping("/role/getrolelist/{loginId}")
  Result<List<String>> getRoleList(
      @PathVariable("loginId") String loginId,
      @RequestHeader(SecurityConstants.SOURCE) String source);
}
